package com.demo.enums;

/**
 * 出院转归1、医嘱出院2、非医嘱出院3、死亡5、其他
 *
 */
public enum DischargeWhereAboutEnum {
    YI_ZHU_CHU_YUAN(1, "医嘱出院"),
    FEI_YI_ZHU_CHU_YUAN(2, "非医嘱出院"),
    SI_WANG(3, "死亡"),
    OTHER(5, "其他");

    private int value;
    private String desc;

    public int getValue() {
        return value;
    }

    public String getDesc() {
        return desc;
    }

    DischargeWhereAboutEnum(int value, String desc) {
        this.value = value;
        this.desc = desc;
    }

    public static DischargeWhereAboutEnum getByValue(Integer value) {
        for (DischargeWhereAboutEnum item : values()) {
            if (item.getValue() == value) {
                return item;
            }
        }
        return null;
    }
}
